/*
 Navicat Premium Data Transfer

 Source Server         : 本地
 Source Server Type    : MySQL
 Source Server Version : 80027
 Source Host           : localhost:3306
 Source Schema         : zhouyi

 Target Server Type    : MySQL
 Target Server Version : 80027
 File Encoding         : 65001

 Date: 01/06/2024 10:15:57
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for address_book
-- ----------------------------
DROP TABLE IF EXISTS `address_book`;
CREATE TABLE `address_book` (
  `id` int NOT NULL AUTO_INCREMENT COMMENT '地址ID',
  `user_id` int NOT NULL COMMENT '用户ID',
  `consignee` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '收件人姓名',
  `sex` enum('male','female') COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '性别',
  `phone` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '联系电话',
  `province_code` char(6) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '省份编码',
  `province_name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '省份名称',
  `city_code` char(6) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '城市编码',
  `city_name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '城市名称',
  `district_code` char(6) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '区县编码',
  `district_name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '区县名称',
  `detail` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '详细地址',
  `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '逻辑删除：1-已删除，0-未删除',
  PRIMARY KEY (`id`),
  UNIQUE KEY `unique_user_consignee` (`user_id`,`consignee`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='用户地址簿';

-- ----------------------------
-- Records of address_book
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for categories
-- ----------------------------
DROP TABLE IF EXISTS `categories`;
CREATE TABLE `categories` (
  `category_id` int NOT NULL AUTO_INCREMENT COMMENT '分类ID',
  `parent_id` int DEFAULT NULL COMMENT '父分类ID',
  `restaurant_id` int DEFAULT NULL COMMENT '餐厅ID',
  `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '分类名称',
  `description` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '分类描述',
  `is_active` tinyint(1) DEFAULT '1' COMMENT '是否启用：1-启用，0-禁用',
  `image_url` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '分类图片URL',
  `sort_order` int NOT NULL DEFAULT '0' COMMENT '排序字段，默认值为0',
  `created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`category_id`),
  KEY `parent_id` (`parent_id`),
  CONSTRAINT `categories_ibfk_1` FOREIGN KEY (`parent_id`) REFERENCES `categories` (`category_id`) ON DELETE SET NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='分类信息表';

-- ----------------------------
-- Records of categories
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for coupons
-- ----------------------------
DROP TABLE IF EXISTS `coupons`;
CREATE TABLE `coupons` (
  `coupon_id` int NOT NULL AUTO_INCREMENT COMMENT '优惠券ID',
  `user_id` int NOT NULL COMMENT '用户ID',
  `restaurant_id` int NOT NULL COMMENT '餐厅ID',
  `code` varchar(255) NOT NULL COMMENT '优惠券代码',
  `discount` decimal(10,2) NOT NULL COMMENT '折扣额度',
  `valid_from` timestamp NOT NULL COMMENT '有效期开始时间',
  `valid_until` timestamp NOT NULL COMMENT '有效期结束时间',
  `usage_limit` int NOT NULL COMMENT '使用次数限制',
  `used_status` enum('unused','used','expired') NOT NULL DEFAULT 'unused' COMMENT '使用状态',
  PRIMARY KEY (`coupon_id`),
  UNIQUE KEY `code` (`code`),
  KEY `user_id` (`user_id`),
  KEY `idx_coupon_id` (`coupon_id`),
  KEY `idx_code` (`code`),
  CONSTRAINT `coupons_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `user` (`user_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='优惠券表';

-- ----------------------------
-- Records of coupons
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for dish_flavors
-- ----------------------------
DROP TABLE IF EXISTS `dish_flavors`;
CREATE TABLE `dish_flavors` (
  `flavor_id` int NOT NULL AUTO_INCREMENT COMMENT '口味ID',
  `restaurant_id` int DEFAULT NULL COMMENT '餐厅ID',
  `flavor_name` varchar(100) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '口味名称',
  `flavor_value` int NOT NULL COMMENT '口味值',
  `created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`flavor_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='菜品口味表';

-- ----------------------------
-- Records of dish_flavors
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for dishes
-- ----------------------------
DROP TABLE IF EXISTS `dishes`;
CREATE TABLE `dishes` (
  `dish_id` int NOT NULL AUTO_INCREMENT,
  `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '菜品名称',
  `description` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '菜品描述',
  `price` decimal(10,2) NOT NULL COMMENT '菜品价格',
  `image_url` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '菜品图片URL',
  `is_active` tinyint(1) DEFAULT '1' COMMENT '菜品是否在售',
  `category_id` int DEFAULT NULL COMMENT '分类ID',
  `dish_flavor_id` int DEFAULT NULL COMMENT '口味ID',
  `restaurant_id` int DEFAULT NULL COMMENT '餐厅ID',
  `created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`dish_id`),
  KEY `category_id` (`category_id`),
  KEY `dish_flavor_id` (`dish_flavor_id`),
  KEY `restaurant_id` (`restaurant_id`),
  CONSTRAINT `dishes_ibfk_1` FOREIGN KEY (`category_id`) REFERENCES `categories` (`category_id`) ON DELETE CASCADE,
  CONSTRAINT `dishes_ibfk_2` FOREIGN KEY (`dish_flavor_id`) REFERENCES `dish_flavors` (`flavor_id`) ON DELETE CASCADE,
  CONSTRAINT `dishes_ibfk_3` FOREIGN KEY (`restaurant_id`) REFERENCES `restaurants` (`restaurant_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='菜品信息表';

-- ----------------------------
-- Records of dishes
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for gen_base_class
-- ----------------------------
DROP TABLE IF EXISTS `gen_base_class`;
CREATE TABLE `gen_base_class` (
  `id` bigint NOT NULL COMMENT 'id',
  `package_name` varchar(200) DEFAULT NULL COMMENT '基类包名',
  `code` varchar(200) DEFAULT NULL COMMENT '基类编码',
  `fields` varchar(500) DEFAULT NULL COMMENT '基类字段，多个用英文逗号分隔',
  `remark` varchar(200) DEFAULT NULL COMMENT '备注',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='基类管理';

-- ----------------------------
-- Records of gen_base_class
-- ----------------------------
BEGIN;
INSERT INTO `gen_base_class` VALUES (1302875019642159105, '${package}.commons.mybatis.entity.BaseEntity', 'BaseEntity', 'id,creator,create_date', '专业版', '2024-05-30 14:14:18');
COMMIT;

-- ----------------------------
-- Table structure for gen_datasource
-- ----------------------------
DROP TABLE IF EXISTS `gen_datasource`;
CREATE TABLE `gen_datasource` (
  `id` bigint NOT NULL COMMENT 'id',
  `db_type` varchar(200) DEFAULT NULL COMMENT '数据库类型 MySQL、Oracle、SQLServer、PostgreSQL',
  `conn_name` varchar(200) NOT NULL COMMENT '连接名',
  `conn_url` varchar(500) DEFAULT NULL COMMENT 'URL',
  `username` varchar(200) DEFAULT NULL COMMENT '用户名',
  `password` varchar(200) DEFAULT NULL COMMENT '密码',
  `status` tinyint DEFAULT NULL COMMENT '状态  0：启用   1：禁用',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='数据源管理';

-- ----------------------------
-- Records of gen_datasource
-- ----------------------------
BEGIN;
INSERT INTO `gen_datasource` VALUES (1302855887882412034, 'MySQL', '本地', 'jdbc:mysql://localhost:3306/qar_cloud?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true', 'qar', '123456', 0, '2024-05-30 14:14:18');
COMMIT;

-- ----------------------------
-- Table structure for gen_field_type
-- ----------------------------
DROP TABLE IF EXISTS `gen_field_type`;
CREATE TABLE `gen_field_type` (
  `id` bigint NOT NULL COMMENT 'id',
  `column_type` varchar(200) DEFAULT NULL COMMENT '字段类型',
  `attr_type` varchar(200) DEFAULT NULL COMMENT '属性类型',
  `package_name` varchar(200) DEFAULT NULL COMMENT '属性包名',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `column_type` (`column_type`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='字段类型管理';

-- ----------------------------
-- Records of gen_field_type
-- ----------------------------
BEGIN;
INSERT INTO `gen_field_type` VALUES (1152452777352425473, 'datetime', 'Date', 'java.util.Date', '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453412995002369, 'date', 'Date', 'java.util.Date', '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453603525455873, 'tinyint', 'Integer', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453660052090881, 'smallint', 'Integer', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453722136178689, 'mediumint', 'Integer', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453808874385409, 'int', 'Integer', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453849735294977, 'integer', 'Integer', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453895029583873, 'bigint', 'Long', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453931373228033, 'float', 'Float', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152453967880450050, 'double', 'Double', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454047601586177, 'decimal', 'BigDecimal', 'java.math.BigDecimal', '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454090760974338, 'bit', 'Boolean', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454147010785282, 'char', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454183136325633, 'varchar', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454312664821761, 'tinytext', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454343820111874, 'text', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454372077137921, 'mediumtext', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454401378545665, 'longtext', 'String', NULL, '2024-05-30 14:14:18');
INSERT INTO `gen_field_type` VALUES (1152454486267064322, 'timestamp', 'Date', 'java.util.Date', '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454630295269378, 'NUMBER', 'Integer', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454715645161474, 'BINARY_INTEGER', 'Integer', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454778828156930, 'BINARY_FLOAT', 'Float', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454828987838466, 'BINARY_DOUBLE', 'Double', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454885745160193, 'VARCHAR2', 'String', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454919756771329, 'NVARCHAR', 'String', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454952568811521, 'NVARCHAR2', 'String', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152454986349735938, 'CLOB', 'String', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152455109695827970, 'int8', 'Long', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152455153002016770, 'int4', 'Integer', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152455184669011969, 'int2', 'Integer', NULL, '2024-05-30 14:14:19');
INSERT INTO `gen_field_type` VALUES (1152455217359417345, 'numeric', 'BigDecimal', 'java.math.BigDecimal', '2024-05-30 14:14:19');
COMMIT;

-- ----------------------------
-- Table structure for gen_table_field
-- ----------------------------
DROP TABLE IF EXISTS `gen_table_field`;
CREATE TABLE `gen_table_field` (
  `id` bigint NOT NULL COMMENT 'id',
  `table_id` bigint DEFAULT NULL COMMENT '表ID',
  `table_name` varchar(200) DEFAULT NULL COMMENT '表名',
  `column_name` varchar(200) DEFAULT NULL COMMENT '列名',
  `column_type` varchar(200) DEFAULT NULL COMMENT '类型',
  `column_comment` varchar(200) DEFAULT NULL COMMENT '列说明',
  `attr_name` varchar(200) DEFAULT NULL COMMENT '属性名',
  `attr_type` varchar(200) DEFAULT NULL COMMENT '属性类型',
  `package_name` varchar(200) DEFAULT NULL COMMENT '属性包名',
  `is_pk` tinyint DEFAULT NULL COMMENT '是否主键 0：否  1：是',
  `is_required` tinyint DEFAULT NULL COMMENT '是否必填 0：否  1：是',
  `is_form` tinyint DEFAULT NULL COMMENT '是否表单字段 0：否  1：是',
  `is_list` tinyint DEFAULT NULL COMMENT '是否列表字段 0：否  1：是',
  `is_query` tinyint DEFAULT NULL COMMENT '是否查询字段 0：否  1：是',
  `query_type` varchar(200) DEFAULT NULL COMMENT '查询方式',
  `form_type` varchar(200) DEFAULT NULL COMMENT '表单类型',
  `dict_name` varchar(200) DEFAULT NULL COMMENT '字典名称',
  `validator_type` varchar(200) DEFAULT NULL COMMENT '效验方式',
  `sort` int DEFAULT NULL COMMENT '排序',
  PRIMARY KEY (`id`),
  KEY `table_name` (`table_name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='代码生成表列';

-- ----------------------------
-- Records of gen_table_field
-- ----------------------------
BEGIN;
INSERT INTO `gen_table_field` VALUES (1308327671502385153, 1308327671447859201, 'gen_test_data', 'id', 'BIGINT', 'id', 'id', 'Long', NULL, 1, 0, 0, 0, 0, '=', 'text', NULL, NULL, 0);
INSERT INTO `gen_table_field` VALUES (1308327671510773761, 1308327671447859201, 'gen_test_data', 'username', 'VARCHAR', '用户名', 'username', 'String', NULL, 0, 1, 1, 1, 1, 'like', 'text', NULL, NULL, 1);
INSERT INTO `gen_table_field` VALUES (1308327671510773762, 1308327671447859201, 'gen_test_data', 'real_name', 'VARCHAR', '姓名', 'realName', 'String', NULL, 0, 1, 1, 1, 0, 'like', 'text', NULL, NULL, 2);
INSERT INTO `gen_table_field` VALUES (1308327671510773763, 1308327671447859201, 'gen_test_data', 'gender', 'TINYINT', '性别', 'gender', 'Integer', NULL, 0, 1, 1, 1, 1, '=', 'select', 'gender', NULL, 3);
INSERT INTO `gen_table_field` VALUES (1308327671510773764, 1308327671447859201, 'gen_test_data', 'email', 'VARCHAR', '邮箱', 'email', 'String', NULL, 0, 1, 1, 1, 0, '=', 'text', NULL, NULL, 4);
INSERT INTO `gen_table_field` VALUES (1308327671514968065, 1308327671447859201, 'gen_test_data', 'notice_type', 'TINYINT', '类型', 'noticeType', 'Integer', NULL, 0, 1, 1, 1, 0, '=', 'radio', 'notice_type', NULL, 5);
INSERT INTO `gen_table_field` VALUES (1308327671514968066, 1308327671447859201, 'gen_test_data', 'content', 'TEXT', '内容', 'content', 'String', NULL, 0, 1, 1, 0, 0, '=', 'editor', NULL, NULL, 6);
INSERT INTO `gen_table_field` VALUES (1308327671514968067, 1308327671447859201, 'gen_test_data', 'creator', 'BIGINT', '创建者', 'creator', 'Long', NULL, 0, 0, 0, 0, 0, '=', 'text', NULL, NULL, 7);
INSERT INTO `gen_table_field` VALUES (1308327671514968068, 1308327671447859201, 'gen_test_data', 'create_date', 'DATETIME', '创建时间', 'createDate', 'Date', 'java.util.Date', 0, 0, 0, 1, 1, '=', 'date', NULL, NULL, 8);
INSERT INTO `gen_table_field` VALUES (1308327671514968069, 1308327671447859201, 'gen_test_data', 'updator', 'BIGINT', '更新者', 'updator', 'Long', NULL, 0, 0, 0, 0, 0, '=', 'text', NULL, NULL, 9);
INSERT INTO `gen_table_field` VALUES (1308327671523356674, 1308327671447859201, 'gen_test_data', 'update_date', 'DATETIME', '更新时间', 'updateDate', 'Date', 'java.util.Date', 0, 0, 0, 0, 0, '=', 'text', NULL, NULL, 10);
COMMIT;

-- ----------------------------
-- Table structure for gen_table_info
-- ----------------------------
DROP TABLE IF EXISTS `gen_table_info`;
CREATE TABLE `gen_table_info` (
  `id` bigint NOT NULL COMMENT 'id',
  `table_name` varchar(200) DEFAULT NULL COMMENT '表名',
  `class_name` varchar(200) DEFAULT NULL COMMENT '类名',
  `table_comment` varchar(200) DEFAULT NULL COMMENT '功能名',
  `author` varchar(200) DEFAULT NULL COMMENT '作者',
  `email` varchar(200) DEFAULT NULL COMMENT '邮箱',
  `package_name` varchar(200) DEFAULT NULL COMMENT '项目包名',
  `version` varchar(200) DEFAULT NULL COMMENT '项目版本号',
  `backend_url` varchar(500) DEFAULT NULL COMMENT '后端访问路径',
  `backend_path` varchar(500) DEFAULT NULL COMMENT '后端生成路径',
  `frontend_path` varchar(500) DEFAULT NULL COMMENT '前端生成路径',
  `module_name` varchar(200) DEFAULT NULL COMMENT '模块名',
  `sub_module_name` varchar(200) DEFAULT NULL COMMENT '子模块名',
  `datasource_id` bigint DEFAULT NULL COMMENT '数据源ID',
  `baseclass_id` bigint DEFAULT NULL COMMENT '基类ID',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `table_name` (`table_name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='代码生成表';

-- ----------------------------
-- Records of gen_table_info
-- ----------------------------
BEGIN;
INSERT INTO `gen_table_info` VALUES (1308327671447859201, 'gen_test_data', 'TestData', '测试功能', 'Mark', 'sunlightcs@gmail.com', 'com.example', '3.0', 'sys', 'D:\\qario\\qar-cloud-tenant\\qar-admin\\qar-admin-server', 'D:\\qario\\qar-cloud-tenant-admin', 'gen', NULL, 0, 1302875019642159105, '2024-05-30 14:14:19');
COMMIT;

-- ----------------------------
-- Table structure for gen_template
-- ----------------------------
DROP TABLE IF EXISTS `gen_template`;
CREATE TABLE `gen_template` (
  `id` bigint NOT NULL COMMENT 'id',
  `name` varchar(200) DEFAULT NULL COMMENT '名称',
  `file_name` varchar(200) DEFAULT NULL COMMENT '文件名',
  `content` mediumtext NOT NULL COMMENT '内容',
  `path` varchar(500) DEFAULT NULL COMMENT '生成路径',
  `status` tinyint DEFAULT NULL COMMENT '状态  0：启用   1：禁用',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='模板管理';

-- ----------------------------
-- Records of gen_template
-- ----------------------------
BEGIN;
INSERT INTO `gen_template` VALUES (1144564443498168321, 'Entity.java', '${ClassName}Entity.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/entity/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1151104918417948674, 'Dao.java', '${ClassName}Dao.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/dao/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222102542519422977, 'Dao.xml', '${ClassName}Dao.xml', '', '${backendPath}/src/main/resources/mapper/${moduleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222811087900602369, 'Service.java', '${ClassName}Service.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/service/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222811738672033793, 'ServiceImpl.java', '${ClassName}ServiceImpl.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/service/${subModuleName!}/impl', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222814109661753346, 'Excel.java', '${ClassName}Excel.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/excel/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222816187301851138, 'DTO.java', '${ClassName}DTO.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/dto/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1222817622663983106, 'Controller.java', '${ClassName}Controller.java', '', '${backendPath}/src/main/java/${packagePath}/${moduleName!}/controller/${subModuleName!}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1304292858898309122, 'list.vue', '${classname}.vue', '', '${frontendPath}/src/views/${backendUrl}', 0, '2024-05-30 14:14:19');
INSERT INTO `gen_template` VALUES (1304293015698169857, 'add-or-update.vue', '${classname}-add-or-update.vue', '', '${frontendPath}/src/views/${backendUrl}', 0, '2024-05-30 14:14:19');
COMMIT;

-- ----------------------------
-- Table structure for gen_test_data
-- ----------------------------
DROP TABLE IF EXISTS `gen_test_data`;
CREATE TABLE `gen_test_data` (
  `id` bigint NOT NULL COMMENT 'id',
  `username` varchar(50) DEFAULT NULL COMMENT '用户名',
  `real_name` varchar(50) DEFAULT NULL COMMENT '姓名',
  `gender` tinyint unsigned DEFAULT NULL COMMENT '性别',
  `email` varchar(100) DEFAULT NULL COMMENT '邮箱',
  `notice_type` tinyint DEFAULT NULL COMMENT '类型',
  `content` text COMMENT '内容',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='测试功能';

-- ----------------------------
-- Records of gen_test_data
-- ----------------------------
BEGIN;
INSERT INTO `gen_test_data` VALUES (1067246875800000001, 'sunlightcs', 'Mark', 0, 'root@qar.io', 0, '<p>qar代码生成器！</p>', 1067246875800000001, '2024-05-30 14:14:19', 1067246875800000001, '2024-05-30 14:14:19');
COMMIT;

-- ----------------------------
-- Table structure for mp_account
-- ----------------------------
DROP TABLE IF EXISTS `mp_account`;
CREATE TABLE `mp_account` (
  `id` bigint NOT NULL COMMENT 'id',
  `name` varchar(100) DEFAULT NULL COMMENT '名称',
  `app_id` varchar(100) DEFAULT NULL COMMENT 'AppID',
  `app_secret` varchar(100) DEFAULT NULL COMMENT 'AppSecret',
  `token` varchar(100) DEFAULT NULL COMMENT 'Token',
  `aes_key` varchar(100) DEFAULT NULL COMMENT 'EncodingAESKey',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='公众号账号管理';

-- ----------------------------
-- Records of mp_account
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for mp_menu
-- ----------------------------
DROP TABLE IF EXISTS `mp_menu`;
CREATE TABLE `mp_menu` (
  `id` bigint NOT NULL COMMENT 'id',
  `menu` varchar(2000) DEFAULT NULL COMMENT '菜单json数据',
  `app_id` varchar(100) DEFAULT NULL COMMENT 'AppID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_app_id` (`app_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='公众号自定义菜单';

-- ----------------------------
-- Records of mp_menu
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for oauth_code
-- ----------------------------
DROP TABLE IF EXISTS `oauth_code`;
CREATE TABLE `oauth_code` (
  `code` varchar(128) DEFAULT NULL,
  `authentication` blob
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='OAuth授权码';

-- ----------------------------
-- Records of oauth_code
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for order_coupon_relations
-- ----------------------------
DROP TABLE IF EXISTS `order_coupon_relations`;
CREATE TABLE `order_coupon_relations` (
  `relation_id` int NOT NULL AUTO_INCREMENT COMMENT '订单优惠券关联ID',
  `order_id` int NOT NULL COMMENT '订单ID',
  `coupon_id` int NOT NULL COMMENT '优惠券ID',
  PRIMARY KEY (`relation_id`),
  UNIQUE KEY `idx_unique_order_coupon` (`order_id`,`coupon_id`),
  KEY `idx_order_id` (`order_id`),
  KEY `idx_coupon_id` (`coupon_id`),
  CONSTRAINT `order_coupon_relations_ibfk_1` FOREIGN KEY (`order_id`) REFERENCES `orders` (`order_id`) ON DELETE CASCADE,
  CONSTRAINT `order_coupon_relations_ibfk_2` FOREIGN KEY (`coupon_id`) REFERENCES `coupons` (`coupon_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='订单优惠券关联表';

-- ----------------------------
-- Records of order_coupon_relations
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for order_details
-- ----------------------------
DROP TABLE IF EXISTS `order_details`;
CREATE TABLE `order_details` (
  `detail_id` int NOT NULL AUTO_INCREMENT COMMENT '订单详情ID',
  `product_name` varchar(255) NOT NULL COMMENT '商品名称',
  `image` varchar(255) DEFAULT NULL COMMENT '商品图片',
  `order_id` int NOT NULL COMMENT '订单ID',
  `dish_id` int DEFAULT NULL COMMENT '菜品ID',
  `setmeal_id` int DEFAULT NULL COMMENT '套餐ID',
  `flavor_id` int DEFAULT NULL COMMENT '口味id',
  `quantity` int NOT NULL COMMENT '数量',
  `amount` decimal(10,2) NOT NULL COMMENT '商品原价',
  `discounted_price` decimal(10,2) NOT NULL COMMENT '打折后价格',
  PRIMARY KEY (`detail_id`),
  KEY `flavor_id` (`flavor_id`),
  KEY `idx_order_id` (`order_id`),
  KEY `idx_dish_id` (`dish_id`),
  KEY `idx_setmeal_id` (`setmeal_id`),
  CONSTRAINT `order_details_ibfk_1` FOREIGN KEY (`order_id`) REFERENCES `orders` (`order_id`) ON DELETE CASCADE,
  CONSTRAINT `order_details_ibfk_2` FOREIGN KEY (`dish_id`) REFERENCES `dishes` (`dish_id`) ON DELETE SET NULL,
  CONSTRAINT `order_details_ibfk_3` FOREIGN KEY (`setmeal_id`) REFERENCES `setmeals` (`setmeal_id`) ON DELETE SET NULL,
  CONSTRAINT `order_details_ibfk_4` FOREIGN KEY (`flavor_id`) REFERENCES `dish_flavors` (`flavor_id`) ON DELETE SET NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='订单详情表';

-- ----------------------------
-- Records of order_details
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for orders
-- ----------------------------
DROP TABLE IF EXISTS `orders`;
CREATE TABLE `orders` (
  `order_id` int NOT NULL AUTO_INCREMENT COMMENT '订单ID',
  `status_description` enum('待付款','待接单','已接单','派送中','已完成','已取消') NOT NULL COMMENT '订单状态',
  `user_id` int NOT NULL COMMENT '用户ID',
  `delivery_address` varchar(255) NOT NULL COMMENT '配送地址',
  `order_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '下单时间',
  `checkout_time` timestamp NULL DEFAULT NULL COMMENT '支付完成时间',
  `pay_method` enum('credit_card','alipay','wechat_pay') DEFAULT NULL COMMENT '支付方式',
  `pay_status` enum('unpaid','paid') DEFAULT NULL COMMENT '支付状态',
  `amount` decimal(10,2) NOT NULL COMMENT '订单金额',
  `remark` text COMMENT '订单备注',
  `delivery_time` datetime DEFAULT NULL COMMENT '预计送达时间',
  PRIMARY KEY (`order_id`),
  KEY `idx_order_id` (`order_id`),
  KEY `idx_user_id` (`user_id`),
  KEY `idx_status_description` (`status_description`),
  CONSTRAINT `orders_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `user` (`user_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='订单表';

-- ----------------------------
-- Records of orders
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for promotions
-- ----------------------------
DROP TABLE IF EXISTS `promotions`;
CREATE TABLE `promotions` (
  `promotion_id` int NOT NULL AUTO_INCREMENT COMMENT '促销活动ID',
  `name` varchar(255) NOT NULL COMMENT '促销活动名称',
  `description` text COMMENT '促销活动描述',
  `start_date` datetime NOT NULL COMMENT '开始日期和时间',
  `end_date` datetime NOT NULL COMMENT '结束日期和时间',
  `status` enum('active','inactive','suspended') NOT NULL COMMENT '活动状态',
  `discount_type` enum('percentage','fixed_amount','buy_x_get_y_free') NOT NULL COMMENT '折扣类型',
  `discount_value` decimal(10,2) NOT NULL COMMENT '折扣值',
  `eligibility` text COMMENT '资格条件',
  `applies_to` text COMMENT '适用范围',
  `limitations` text COMMENT '限制条件',
  `restaurant_id` int NOT NULL COMMENT '餐厅ID',
  `created_by` int DEFAULT NULL COMMENT '创建者ID',
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`promotion_id`),
  KEY `created_by` (`created_by`),
  KEY `idx_restaurant_id` (`restaurant_id`),
  CONSTRAINT `promotions_ibfk_1` FOREIGN KEY (`restaurant_id`) REFERENCES `restaurants` (`restaurant_id`) ON DELETE RESTRICT,
  CONSTRAINT `promotions_ibfk_2` FOREIGN KEY (`created_by`) REFERENCES `user` (`user_id`) ON DELETE SET NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='促销活动表';

-- ----------------------------
-- Records of promotions
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for restaurants
-- ----------------------------
DROP TABLE IF EXISTS `restaurants`;
CREATE TABLE `restaurants` (
  `restaurant_id` int NOT NULL AUTO_INCREMENT COMMENT '餐厅ID',
  `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '餐厅名称',
  `description` text COLLATE utf8mb4_unicode_ci COMMENT '餐厅描述',
  `latitude` decimal(11,8) NOT NULL COMMENT '纬度',
  `longitude` decimal(11,8) NOT NULL COMMENT '经度',
  `address` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '餐厅地址',
  `operating_hours` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '营业时间',
  `rating` decimal(2,1) DEFAULT NULL COMMENT '餐厅评分',
  `created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`restaurant_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='餐厅信息表';

-- ----------------------------
-- Records of restaurants
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for reviews
-- ----------------------------
DROP TABLE IF EXISTS `reviews`;
CREATE TABLE `reviews` (
  `review_id` int NOT NULL AUTO_INCREMENT COMMENT '评论ID',
  `user_id` int NOT NULL COMMENT '用户ID',
  `restaurant_id` int NOT NULL COMMENT '餐厅ID',
  `review_content` text NOT NULL COMMENT '评论内容',
  `rating` tinyint NOT NULL COMMENT '评分',
  `review_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '评论时间',
  PRIMARY KEY (`review_id`),
  KEY `idx_review_id` (`review_id`),
  KEY `idx_user_id` (`user_id`),
  KEY `idx_restaurant_id` (`restaurant_id`),
  CONSTRAINT `reviews_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `user` (`user_id`) ON DELETE CASCADE,
  CONSTRAINT `reviews_ibfk_2` FOREIGN KEY (`restaurant_id`) REFERENCES `restaurants` (`restaurant_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='评论表';

-- ----------------------------
-- Records of reviews
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for setmeal_dishes
-- ----------------------------
DROP TABLE IF EXISTS `setmeal_dishes`;
CREATE TABLE `setmeal_dishes` (
  `setmeal_id` int NOT NULL COMMENT '套餐ID',
  `dish_id` int NOT NULL COMMENT '菜品ID',
  PRIMARY KEY (`setmeal_id`,`dish_id`),
  KEY `dish_id` (`dish_id`),
  CONSTRAINT `setmeal_dishes_ibfk_1` FOREIGN KEY (`setmeal_id`) REFERENCES `setmeals` (`setmeal_id`) ON DELETE CASCADE,
  CONSTRAINT `setmeal_dishes_ibfk_2` FOREIGN KEY (`dish_id`) REFERENCES `dishes` (`dish_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='套餐与菜品关系表';

-- ----------------------------
-- Records of setmeal_dishes
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for setmeals
-- ----------------------------
DROP TABLE IF EXISTS `setmeals`;
CREATE TABLE `setmeals` (
  `setmeal_id` int NOT NULL AUTO_INCREMENT COMMENT '套餐ID',
  `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '套餐名称',
  `price` decimal(10,2) NOT NULL COMMENT '套餐价格',
  `is_active` tinyint(1) DEFAULT '1' COMMENT '状态：1-启用，0-禁用',
  `category_id` int DEFAULT NULL COMMENT '分类ID',
  `restaurant_id` int DEFAULT NULL COMMENT '餐厅ID',
  `created_by` int DEFAULT NULL COMMENT '创建者ID',
  `updated_by` int DEFAULT NULL COMMENT '更新者ID',
  `create_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `update_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`setmeal_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='套餐信息表';

-- ----------------------------
-- Records of setmeals
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sku_audit_logs
-- ----------------------------
DROP TABLE IF EXISTS `sku_audit_logs`;
CREATE TABLE `sku_audit_logs` (
  `audit_id` bigint NOT NULL AUTO_INCREMENT COMMENT '审计记录ID',
  `sku_id` bigint NOT NULL COMMENT '关联的SKU ID',
  `action` enum('create','update','delete') NOT NULL COMMENT '操作类型',
  `changed_fields` json DEFAULT NULL COMMENT '变更的字段及前后值（JSON格式）',
  `user_id` bigint DEFAULT NULL COMMENT '执行操作的用户ID',
  `timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '操作时间',
  PRIMARY KEY (`audit_id`),
  KEY `idx_sku_id` (`sku_id`),
  KEY `idx_timestamp` (`timestamp`),
  CONSTRAINT `sku_audit_logs_ibfk_1` FOREIGN KEY (`sku_id`) REFERENCES `skus` (`sku_id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='SKU审计日志表';

-- ----------------------------
-- Records of sku_audit_logs
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for skus
-- ----------------------------
DROP TABLE IF EXISTS `skus`;
CREATE TABLE `skus` (
  `sku_id` bigint NOT NULL AUTO_INCREMENT COMMENT 'SKU ID',
  `dish_id` int NOT NULL COMMENT '关联的菜品ID',
  `flavor` varchar(255) DEFAULT NULL COMMENT '口味',
  `specification` json DEFAULT NULL COMMENT '规格（JSON格式）',
  `stock_quantity` int NOT NULL DEFAULT '0' COMMENT '库存数量',
  `stock_threshold` int NOT NULL DEFAULT '0' COMMENT '库存预警阈值',
  `price` decimal(10,2) NOT NULL COMMENT '售价',
  `cost` decimal(10,2) DEFAULT NULL COMMENT '成本价',
  `image_url` varchar(255) DEFAULT NULL COMMENT 'SKU图片URL（如有不同）',
  `status` enum('active','inactive','pending','discontinued') NOT NULL DEFAULT 'active' COMMENT 'SKU状态',
  `approval_status` enum('pending','approved','rejected') NOT NULL DEFAULT 'pending' COMMENT '审批状态',
  `promotion_info` json DEFAULT NULL COMMENT '促销活动信息（JSON格式）',
  `version` int NOT NULL DEFAULT '1' COMMENT '版本号',
  `create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `update_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  `supplier_id` bigint DEFAULT NULL COMMENT '供应商ID',
  PRIMARY KEY (`sku_id`),
  KEY `idx_sku_id` (`sku_id`),
  KEY `idx_dish_id` (`dish_id`),
  KEY `idx_supplier_id` (`supplier_id`),
  CONSTRAINT `skus_ibfk_1` FOREIGN KEY (`dish_id`) REFERENCES `dishes` (`dish_id`) ON DELETE CASCADE,
  CONSTRAINT `skus_ibfk_2` FOREIGN KEY (`supplier_id`) REFERENCES `suppliers` (`supplier_id`) ON DELETE SET NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='SKU表';

-- ----------------------------
-- Records of skus
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for suppliers
-- ----------------------------
DROP TABLE IF EXISTS `suppliers`;
CREATE TABLE `suppliers` (
  `supplier_id` bigint NOT NULL AUTO_INCREMENT COMMENT '供应商ID',
  `name` varchar(255) NOT NULL COMMENT '供应商名称',
  `contact_name` varchar(255) DEFAULT NULL COMMENT '联系人姓名',
  `email` varchar(255) DEFAULT NULL COMMENT '供应商电子邮件',
  `phone` varchar(20) DEFAULT NULL COMMENT '联系电话',
  `address` varchar(255) DEFAULT NULL COMMENT '供应商地址',
  `city` varchar(100) DEFAULT NULL COMMENT '城市',
  `state` varchar(100) DEFAULT NULL COMMENT '州/省',
  `postal_code` varchar(20) DEFAULT NULL COMMENT '邮政编码',
  `country` varchar(100) DEFAULT NULL COMMENT '国家',
  `credit_limit` decimal(10,2) DEFAULT NULL COMMENT '信用额度',
  `status` enum('active','inactive') NOT NULL DEFAULT 'active' COMMENT '供应商状态',
  `create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
  `update_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
  PRIMARY KEY (`supplier_id`),
  UNIQUE KEY `email` (`email`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='供应商表';

-- ----------------------------
-- Records of suppliers
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_dept
-- ----------------------------
DROP TABLE IF EXISTS `sys_dept`;
CREATE TABLE `sys_dept` (
  `id` bigint NOT NULL COMMENT 'id',
  `pid` bigint DEFAULT NULL COMMENT '上级ID',
  `pids` varchar(500) DEFAULT NULL COMMENT '所有上级ID，用逗号分开',
  `name` varchar(50) DEFAULT NULL COMMENT '部门名称',
  `sort` int unsigned DEFAULT NULL COMMENT '排序',
  `del_flag` tinyint unsigned DEFAULT NULL COMMENT '删除标识  0：未删除    1：删除',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  KEY `idx_pid` (`pid`),
  KEY `idx_del_flag` (`del_flag`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='部门管理';

-- ----------------------------
-- Records of sys_dept
-- ----------------------------
BEGIN;
INSERT INTO `sys_dept` VALUES (1067246875800000061, 1067246875800000062, '1067246875800000065,1067246875800000062', '技术部', 2, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000062, 1067246875800000065, '1067246875800000065', '长沙分公司', 1, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000063, 1067246875800000065, '1067246875800000065', '上海分公司', 0, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000064, 1067246875800000063, '1067246875800000065,1067246875800000063', '市场部', 0, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000065, 0, '0', 'qar集团', 0, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000066, 1067246875800000063, '1067246875800000065,1067246875800000063', '销售部', 0, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dept` VALUES (1067246875800000067, 1067246875800000062, '1067246875800000065,1067246875800000062', '产品部', 1, 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for sys_dict_data
-- ----------------------------
DROP TABLE IF EXISTS `sys_dict_data`;
CREATE TABLE `sys_dict_data` (
  `id` bigint NOT NULL COMMENT 'id',
  `dict_type_id` bigint NOT NULL COMMENT '字典类型ID',
  `dict_label` varchar(255) NOT NULL COMMENT '字典标签',
  `dict_value` varchar(255) DEFAULT NULL COMMENT '字典值',
  `remark` varchar(255) DEFAULT NULL COMMENT '备注',
  `sort` int unsigned DEFAULT NULL COMMENT '排序',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_dict_type_value` (`dict_type_id`,`dict_value`),
  KEY `idx_sort` (`sort`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='字典数据';

-- ----------------------------
-- Records of sys_dict_data
-- ----------------------------
BEGIN;
INSERT INTO `sys_dict_data` VALUES (1160061112075464705, 1160061077912858625, '男', '0', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1160061146967879681, 1160061077912858625, '女', '1', '', 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1160061190127267841, 1160061077912858625, '保密', '2', '', 2, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1225814069634195457, 1225813644059140097, '公告', '0', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1225814107559092225, 1225813644059140097, '会议', '1', '', 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1225814271879340034, 1225813644059140097, '其他', '2', '', 2, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1341593562419445762, 1341593474355838978, '停用', '0', '', 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1341593595407646722, 1341593474355838978, '正常', '1', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1343069765549191170, 1343069688596295682, '已取消', '-1', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1343069839847092226, 1343069688596295682, '等待付款', '0', '', 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_data` VALUES (1343069914518286337, 1343069688596295682, '已完成', '1', '', 2, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for sys_dict_type
-- ----------------------------
DROP TABLE IF EXISTS `sys_dict_type`;
CREATE TABLE `sys_dict_type` (
  `id` bigint NOT NULL COMMENT 'id',
  `dict_type` varchar(100) NOT NULL COMMENT '字典类型',
  `dict_name` varchar(255) NOT NULL COMMENT '字典名称',
  `remark` varchar(255) DEFAULT NULL COMMENT '备注',
  `sort` int unsigned DEFAULT NULL COMMENT '排序',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `dict_type` (`dict_type`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='字典类型';

-- ----------------------------
-- Records of sys_dict_type
-- ----------------------------
BEGIN;
INSERT INTO `sys_dict_type` VALUES (1160061077912858625, 'gender', '性别', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_type` VALUES (1225813644059140097, 'notice_type', '站内通知-类型', '', 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_type` VALUES (1341593474355838978, 'post_status', '岗位管理状态', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
INSERT INTO `sys_dict_type` VALUES (1343069688596295682, 'order_status', '订单状态', '', 0, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for sys_language
-- ----------------------------
DROP TABLE IF EXISTS `sys_language`;
CREATE TABLE `sys_language` (
  `table_name` varchar(32) NOT NULL COMMENT '表名',
  `table_id` bigint NOT NULL COMMENT '表主键',
  `field_name` varchar(32) NOT NULL COMMENT '字段名',
  `field_value` varchar(200) NOT NULL COMMENT '字段值',
  `language` varchar(10) NOT NULL COMMENT '语言',
  PRIMARY KEY (`table_name`,`table_id`,`field_name`,`language`),
  KEY `idx_table_id` (`table_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='国际化';

-- ----------------------------
-- Records of sys_language
-- ----------------------------
BEGIN;
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000002, 'name', 'Authority Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000002, 'name', '权限管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000002, 'name', '權限管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000003, 'name', 'User Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000003, 'name', '用户管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000003, 'name', '用戶管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000004, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000004, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000004, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000005, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000005, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000005, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000006, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000006, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000006, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000007, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000007, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000007, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000008, 'name', 'Export', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000008, 'name', '导出', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000008, 'name', '導出', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000009, 'name', 'Department Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000009, 'name', '部门管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000009, 'name', '部門管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000010, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000010, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000010, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000011, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000011, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000011, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000012, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000012, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000012, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000013, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000013, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000013, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000014, 'name', 'Role Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000014, 'name', '角色管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000014, 'name', '角色管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000015, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000015, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000015, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000016, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000016, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000016, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000017, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000017, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000017, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000018, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000018, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000018, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000019, 'name', 'Setting', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000019, 'name', '系统设置', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000019, 'name', '系統設置', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000020, 'name', 'Menu Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000020, 'name', '菜单管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000020, 'name', '菜單管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000021, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000021, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000021, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000022, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000022, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000022, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000023, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000023, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000023, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000024, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000024, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000024, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000025, 'name', 'Parameter Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000025, 'name', '参数管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000025, 'name', '參數管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000026, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000026, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000026, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000027, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000027, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000027, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000028, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000028, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000028, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000029, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000029, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000029, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000030, 'name', 'Export', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000030, 'name', '导出', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000030, 'name', '導出', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000031, 'name', 'Dict Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000031, 'name', '字典管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000031, 'name', '字典管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000032, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000032, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000032, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000033, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000033, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000033, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000034, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000034, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000034, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000035, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000035, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000035, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000036, 'name', 'Log Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000036, 'name', '日志管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000036, 'name', '日誌管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000037, 'name', 'Login Log', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000037, 'name', '登录日志', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000037, 'name', '登錄日誌', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000038, 'name', 'Operation Log', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000038, 'name', '操作日志', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000038, 'name', '操作日誌', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000039, 'name', 'Error Log', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000039, 'name', '异常日志', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000039, 'name', '異常日誌', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000040, 'name', 'System Monitoring', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000040, 'name', '系统监控', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000040, 'name', '系統監控', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000041, 'name', 'Service Monitoring', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000041, 'name', '服务监控', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000041, 'name', '服務監控', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000042, 'name', 'Swagger Api', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000042, 'name', '接口文档', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000042, 'name', '接口文檔', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000056, 'name', 'Message Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000056, 'name', '消息管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000056, 'name', '消息管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000057, 'name', 'SMS Service', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000057, 'name', '短信服务', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000057, 'name', '短信服務', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000058, 'name', 'Mail Template', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000058, 'name', '邮件模板', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000058, 'name', '郵件模板', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000059, 'name', 'Mail Log', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000059, 'name', '邮件发送记录', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000059, 'name', '郵件發送記錄', 'zh-TW ');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000060, 'name', 'File Upload', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000060, 'name', '文件上传', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000060, 'name', '文件上傳', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000301, 'name', 'SMS History', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000301, 'name', '短信发送记录', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000301, 'name', '短信發送記錄', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000401, 'name', 'Station Notice', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000401, 'name', '站内通知', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000401, 'name', '站內通知', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000402, 'name', 'Notice Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000402, 'name', '通知管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000402, 'name', '通知管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000403, 'name', 'My Notice', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000403, 'name', '我的通知', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1067246875800000403, 'name', '我的通知', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164489061834969089, 'name', 'Administrative Regions', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164489061834969089, 'name', '行政区域', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164489061834969089, 'name', '行政區域', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492214366130178, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492214366130178, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492214366130178, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492872829915138, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492872829915138, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164492872829915138, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493252347318273, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493252347318273, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493252347318273, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493391254278145, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493391254278145, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1164493391254278145, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1176372255559024642, 'name', 'Demo', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1176372255559024642, 'name', '功能示例', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1176372255559024642, 'name', '功能示例', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1206460008292216834, 'name', 'News Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1206460008292216834, 'name', '新闻管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1206460008292216834, 'name', '新聞管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501800, 'name', 'ECharts', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501800, 'name', 'ECharts', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501800, 'name', 'ECharts', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501825, 'name', 'Master And Child', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501825, 'name', '主子表演示', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501825, 'name', '主子表演示', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501826, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501826, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501826, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501827, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501827, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501827, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501828, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501828, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501828, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501829, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501829, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1270380959719501829, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278047072649217, 'name', 'Report Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278047072649217, 'name', '报表管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278047072649217, 'name', '報表管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278435729440769, 'name', 'Report Design', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278435729440769, 'name', '报表设计器', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300278435729440769, 'name', '報表設計器', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300381796852060161, 'name', 'Report List', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300381796852060161, 'name', '报表列表', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1300381796852060161, 'name', '報表列表', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850622416084993, 'name', 'DevTools', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850622416084993, 'name', '开发者工具', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850622416084993, 'name', '開發者工具', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850783288614913, 'name', 'DataSource', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850783288614913, 'name', '数据源管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302850783288614913, 'name', '數據源管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302862890696564738, 'name', 'Field Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302862890696564738, 'name', '字段管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302862890696564738, 'name', '字段管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302874751835848705, 'name', 'BaseClass', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302874751835848705, 'name', '基类管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1302874751835848705, 'name', '基類管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304081184014635010, 'name', 'Template', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304081184014635010, 'name', '模板管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304081184014635010, 'name', '模板管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304802103569809410, 'name', 'Code Generation', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304802103569809410, 'name', '代码生成工具', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1304802103569809410, 'name', '代碼生成工具', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305513187675144193, 'name', 'Parameter Config', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305513187675144193, 'name', '参数配置', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305513187675144193, 'name', '參數配置', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305532398162145281, 'name', 'Config Info', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305532398162145281, 'name', '配置信息', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1305532398162145281, 'name', '配置信息', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347266, 'name', 'Page Design', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347266, 'name', '页面表单设计', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347266, 'name', '頁面表單設計', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347268, 'name', 'Large Screen', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347268, 'name', '大屏设计', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1340949288542347268, 'name', '大屏設計', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622612987906, 'name', 'Job Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622612987906, 'name', '岗位管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622612987906, 'name', '崗位管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622688485377, 'name', 'View', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622688485377, 'name', '查看', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622688485377, 'name', '查看', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622755594242, 'name', 'Add', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622755594242, 'name', '新增', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622755594242, 'name', '新增', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622835286018, 'name', 'Edit', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622835286018, 'name', '修改', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622835286018, 'name', '修改', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622902394881, 'name', 'Delete', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622902394881, 'name', '删除', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341596622902394881, 'name', '刪除', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341676084016852994, 'name', 'Excel Demo', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341676084016852994, 'name', 'Excel导入演示', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1341676084016852994, 'name', 'Excel導入演示', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074487777677313, 'name', 'Pay Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074487777677313, 'name', '支付管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074487777677313, 'name', '支付管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074685589442561, 'name', 'Order Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074685589442561, 'name', '订单管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074685589442561, 'name', '訂單管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074794440019970, 'name', 'AliPay Log', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074794440019970, 'name', '支付宝回调日志', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1343074794440019970, 'name', '支付寶回調日誌', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419551957005963266, 'name', 'Wechat Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419551957005963266, 'name', '微信管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419551957005963266, 'name', '微信管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419553543706972161, 'name', 'Mp Management', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419553543706972161, 'name', '公众号管理', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419553543706972161, 'name', '公眾號管理', 'zh-TW');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419963799817691137, 'name', 'Custom Menu', 'en-US');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419963799817691137, 'name', '自定义菜单', 'zh-CN');
INSERT INTO `sys_language` VALUES ('sys_menu', 1419963799817691137, 'name', '自定義選單', 'zh-TW');
COMMIT;

-- ----------------------------
-- Table structure for sys_log_error
-- ----------------------------
DROP TABLE IF EXISTS `sys_log_error`;
CREATE TABLE `sys_log_error` (
  `id` bigint NOT NULL COMMENT 'id',
  `module` varchar(50) DEFAULT NULL COMMENT '模块名称，如：sys',
  `request_uri` varchar(200) DEFAULT NULL COMMENT '请求URI',
  `request_method` varchar(20) DEFAULT NULL COMMENT '请求方式',
  `request_params` text COMMENT '请求参数',
  `user_agent` varchar(500) DEFAULT NULL COMMENT '用户代理',
  `ip` varchar(160) DEFAULT NULL COMMENT '操作IP',
  `error_info` text COMMENT '异常信息',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_module` (`module`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='异常日志';

-- ----------------------------
-- Records of sys_log_error
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_log_login
-- ----------------------------
DROP TABLE IF EXISTS `sys_log_login`;
CREATE TABLE `sys_log_login` (
  `id` bigint NOT NULL COMMENT 'id',
  `operation` tinyint unsigned DEFAULT NULL COMMENT '用户操作   0：用户登录   1：用户退出',
  `user_agent` varchar(500) DEFAULT NULL COMMENT '用户代理',
  `ip` varchar(160) DEFAULT NULL COMMENT '操作IP',
  `creator_name` varchar(50) DEFAULT NULL COMMENT '用户名',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='登录日志';

-- ----------------------------
-- Records of sys_log_login
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_log_operation
-- ----------------------------
DROP TABLE IF EXISTS `sys_log_operation`;
CREATE TABLE `sys_log_operation` (
  `id` bigint NOT NULL COMMENT 'id',
  `module` varchar(32) DEFAULT NULL COMMENT '模块名称，如：sys',
  `operation` varchar(50) DEFAULT NULL COMMENT '用户操作',
  `request_uri` varchar(200) DEFAULT NULL COMMENT '请求URI',
  `request_method` varchar(20) DEFAULT NULL COMMENT '请求方式',
  `request_params` text COMMENT '请求参数',
  `request_time` int unsigned NOT NULL COMMENT '请求时长(毫秒)',
  `user_agent` varchar(500) DEFAULT NULL COMMENT '用户代理',
  `ip` varchar(160) DEFAULT NULL COMMENT '操作IP',
  `status` tinyint unsigned NOT NULL COMMENT '状态  0：失败   1：成功',
  `creator_name` varchar(50) DEFAULT NULL COMMENT '用户名',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_module` (`module`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='操作日志';

-- ----------------------------
-- Records of sys_log_operation
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_mail_log
-- ----------------------------
DROP TABLE IF EXISTS `sys_mail_log`;
CREATE TABLE `sys_mail_log` (
  `id` bigint NOT NULL COMMENT 'id',
  `template_id` bigint NOT NULL COMMENT '邮件模板ID',
  `mail_from` varchar(200) DEFAULT NULL COMMENT '发送者',
  `mail_to` varchar(400) DEFAULT NULL COMMENT '收件人',
  `mail_cc` varchar(400) DEFAULT NULL COMMENT '抄送者',
  `subject` varchar(200) DEFAULT NULL COMMENT '邮件主题',
  `content` text COMMENT '邮件正文',
  `status` tinyint unsigned DEFAULT NULL COMMENT '发送状态  0：失败  1：成功',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='邮件发送记录';

-- ----------------------------
-- Records of sys_mail_log
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_mail_template
-- ----------------------------
DROP TABLE IF EXISTS `sys_mail_template`;
CREATE TABLE `sys_mail_template` (
  `id` bigint NOT NULL COMMENT 'id',
  `name` varchar(100) DEFAULT NULL COMMENT '模板名称',
  `subject` varchar(200) DEFAULT NULL COMMENT '邮件主题',
  `content` text COMMENT '邮件正文',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='邮件模板';

-- ----------------------------
-- Records of sys_mail_template
-- ----------------------------
BEGIN;
INSERT INTO `sys_mail_template` VALUES (1067246875800000147, '验证码模板', 'qar注册验证码', '<p>qar注册验证码：${code}</p>', NULL, '2024-05-30 14:14:47', NULL, NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_menu
-- ----------------------------
DROP TABLE IF EXISTS `sys_menu`;
CREATE TABLE `sys_menu` (
  `id` bigint NOT NULL COMMENT 'id',
  `pid` bigint DEFAULT NULL COMMENT '上级ID，一级菜单为0',
  `url` varchar(200) DEFAULT NULL COMMENT '菜单URL',
  `menu_type` tinyint unsigned DEFAULT NULL COMMENT '类型   0：菜单   1：按钮',
  `open_style` tinyint unsigned DEFAULT NULL COMMENT '打开方式   0：内部   1：外部',
  `icon` varchar(50) DEFAULT NULL COMMENT '菜单图标',
  `permissions` varchar(200) DEFAULT NULL COMMENT '权限标识，如：sys:menu:save',
  `sort` int DEFAULT NULL COMMENT '排序',
  `del_flag` tinyint unsigned DEFAULT NULL COMMENT '删除标识  0：未删除    1：删除',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  KEY `idx_pid` (`pid`),
  KEY `idx_del_flag` (`del_flag`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='菜单管理';

-- ----------------------------
-- Records of sys_menu
-- ----------------------------
BEGIN;
INSERT INTO `sys_menu` VALUES (1067246875800000002, 0, '', 0, 0, 'icon-lock', '', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000003, 1067246875800000002, 'sys/user', 0, 0, 'icon-user', '', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000004, 1067246875800000003, '', 1, 0, '', 'sys:user:page,sys:user:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000005, 1067246875800000003, '', 1, 0, '', 'sys:user:save,sys:dept:list,sys:role:list', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000006, 1067246875800000003, '', 1, 0, '', 'sys:user:update,sys:dept:list,sys:role:list', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000007, 1067246875800000003, '', 1, 0, '', 'sys:user:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000008, 1067246875800000003, '', 1, 0, '', 'sys:user:export', 4, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000009, 1067246875800000002, 'sys/dept', 0, 0, 'icon-apartment', '', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000010, 1067246875800000009, '', 1, 0, '', 'sys:dept:list,sys:dept:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000011, 1067246875800000009, '', 1, 0, '', 'sys:dept:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000012, 1067246875800000009, '', 1, 0, '', 'sys:dept:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000013, 1067246875800000009, '', 1, 0, '', 'sys:dept:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000014, 1067246875800000002, 'sys/role', 0, 0, 'icon-team', '', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000015, 1067246875800000014, '', 1, 0, '', 'sys:role:page,sys:role:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000016, 1067246875800000014, '', 1, 0, '', 'sys:role:save,sys:menu:select,sys:dept:list', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000017, 1067246875800000014, '', 1, 0, '', 'sys:role:update,sys:menu:select,sys:dept:list', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000018, 1067246875800000014, '', 1, 0, '', 'sys:role:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000019, 0, '', 0, 0, 'icon-setting', NULL, 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000020, 1067246875800000019, 'sys/menu', 0, 0, 'icon-unorderedlist', NULL, 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000021, 1067246875800000020, NULL, 1, 0, NULL, 'sys:menu:list,sys:menu:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000022, 1067246875800000020, NULL, 1, 0, NULL, 'sys:menu:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000023, 1067246875800000020, NULL, 1, 0, NULL, 'sys:menu:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000024, 1067246875800000020, NULL, 1, 0, NULL, 'sys:menu:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000025, 1067246875800000019, 'sys/params', 0, 0, 'icon-fileprotect', '', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000026, 1067246875800000025, NULL, 1, 0, NULL, 'sys:params:page,sys:params:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000027, 1067246875800000025, NULL, 1, 0, NULL, 'sys:params:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000028, 1067246875800000025, NULL, 1, 0, NULL, 'sys:params:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000029, 1067246875800000025, NULL, 1, 0, NULL, 'sys:params:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000030, 1067246875800000025, '', 1, 0, NULL, 'sys:params:export', 4, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000031, 1067246875800000019, 'sys/dict-type', 0, 0, 'icon-gold', '', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000032, 1067246875800000031, '', 1, 0, '', 'sys:dict:page,sys:dict:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000033, 1067246875800000031, '', 1, 0, '', 'sys:dict:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000034, 1067246875800000031, '', 1, 0, '', 'sys:dict:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000035, 1067246875800000031, '', 1, 0, '', 'sys:dict:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000036, 0, '', 0, 0, 'icon-container', '', 4, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000037, 1067246875800000036, 'sys/log-login', 0, 0, 'icon-filedone', 'sys:log:login', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000038, 1067246875800000036, 'sys/log-operation', 0, 0, 'icon-solution', 'sys:log:operation', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000039, 1067246875800000036, 'sys/log-error', 0, 0, 'icon-file-exception', 'sys:log:error', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000040, 0, '', 0, 0, 'icon-desktop', '', 5, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000041, 1067246875800000040, '{{ApiUrl}}/monitor', 0, 0, 'icon-medicinebox', '', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000042, 1067246875800000040, '{{ApiUrl}}/doc.html', 0, 1, 'icon-file-word', '', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000056, 0, '', 0, 0, 'icon-message', '', 3, 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_menu` VALUES (1067246875800000057, 1067246875800000056, 'message/sms', 0, 0, 'icon-layout', 'sys:sms:all', 0, 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_menu` VALUES (1067246875800000058, 1067246875800000056, 'message/mail-template', 0, 0, 'icon-appstore', 'sys:mail:all', 1, 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_menu` VALUES (1067246875800000059, 1067246875800000056, 'message/mail-log', 0, 0, 'icon-save', 'sys:mail:log', 2, 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_menu` VALUES (1067246875800000060, 1067246875800000019, 'oss/oss', 0, 0, 'icon-upload', 'sys:oss:all', 4, 0, 1067246875800000001, '2024-05-30 14:15:12', 1067246875800000001, '2024-05-30 14:15:12');
INSERT INTO `sys_menu` VALUES (1067246875800000301, 1067246875800000056, 'message/sms-log', 0, 0, 'icon-layout', 'sys:smslog:all', 1, 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_menu` VALUES (1067246875800000401, 0, '', 0, 0, 'icon-bell', '', 4, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000402, 1067246875800000401, 'sys/notice', 0, 0, 'icon-bell', 'sys:notice:all,sys:dept:list', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1067246875800000403, 1067246875800000401, 'sys/notice-user', 0, 0, 'icon-notification', 'sys:notice:all', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1164489061834969089, 1067246875800000019, 'sys/region', 0, 0, 'icon-location', '0', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1164492214366130178, 1164489061834969089, '', 1, 0, '', 'sys:region:list,sys:region:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1164492872829915138, 1164489061834969089, '', 1, 0, '', 'sys:region:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1164493252347318273, 1164489061834969089, '', 1, 0, '', 'sys:region:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1164493391254278145, 1164489061834969089, '', 1, 0, '', 'sys:region:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1176372255559024642, 0, '', 0, 0, 'icon-windows', '', 999, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1206460008292216834, 1176372255559024642, 'sys/news', 0, 0, 'icon-file-word', 'demo:news:all', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501800, 1176372255559024642, 'sys/charts', 0, 0, 'icon-tag', '', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501825, 1176372255559024642, 'sys/product', 0, 0, 'icon-tag', NULL, 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501826, 1270380959719501825, NULL, 1, 0, NULL, 'demo:product:page,demo:product:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501827, 1270380959719501825, NULL, 1, 0, NULL, 'demo:product:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501828, 1270380959719501825, NULL, 1, 0, NULL, 'demo:product:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1270380959719501829, 1270380959719501825, NULL, 1, 0, NULL, 'demo:product:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1300278047072649217, 0, '', 0, 0, 'icon-filesearch', '', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1300278435729440769, 1300278047072649217, '{{ApiUrl}}/sys/ureport/designer', 0, 0, 'icon-book', '', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1300381796852060161, 1300278047072649217, 'sys/ureport', 0, 0, 'icon-up-circle', 'sys:ureport:all', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1302850622416084993, 0, '', 0, 0, 'icon-rocket', '', 3, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1302850783288614913, 1305532398162145281, 'devtools/datasource', 0, 0, 'icon-sync', '', 0, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1302862890696564738, 1305532398162145281, 'devtools/fieldtype', 0, 0, 'icon-eye', '', 1, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1302874751835848705, 1305532398162145281, 'devtools/baseclass', 0, 0, 'icon-info-circle', '', 3, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1304081184014635010, 1305532398162145281, 'devtools/template', 0, 0, 'icon-up-circle', '', 3, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1304802103569809410, 1302850622416084993, 'devtools/generator', 0, 0, 'icon-tags', '', 0, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1305513187675144193, 1305532398162145281, 'devtools/param', 0, 0, 'icon-setting', '', 5, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1305532398162145281, 1302850622416084993, '', 0, 0, 'icon-setting', '', 3, 0, 1067246875800000001, '2024-05-30 14:14:17', 1067246875800000001, '2024-05-30 14:14:17');
INSERT INTO `sys_menu` VALUES (1340949288542347266, 1302850622416084993, 'form-generator/form', 0, 0, 'icon-edit-square', '', 0, 0, 1067246875800000001, '2024-05-30 14:14:19', 1067246875800000001, '2024-05-30 14:14:19');
INSERT INTO `sys_menu` VALUES (1340949288542347268, 1302850622416084993, 'http://datav.qar.io', 0, 1, 'icon-select', '', 0, 0, 1067246875800000001, '2024-05-30 14:14:19', 1067246875800000001, '2024-05-30 14:14:19');
INSERT INTO `sys_menu` VALUES (1341596622612987906, 1067246875800000002, 'sys/post', 0, 0, 'icon-pic-left', NULL, 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1341596622688485377, 1341596622612987906, NULL, 1, 0, NULL, 'sys:post:page,sys:post:info', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1341596622755594242, 1341596622612987906, NULL, 1, 0, NULL, 'sys:post:save', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1341596622835286018, 1341596622612987906, NULL, 1, 0, NULL, 'sys:post:update', 2, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1341596622902394881, 1341596622612987906, NULL, 1, 0, NULL, 'sys:post:delete', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1341676084016852994, 1176372255559024642, 'sys/excel', 0, 0, 'icon-table', 'demo:excel:all', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1343074487777677313, 0, '', 0, 0, 'icon-Dollar', '', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1343074685589442561, 1343074487777677313, 'pay/order', 0, 0, 'icon-unorderedlist', 'pay:order:all', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1343074794440019970, 1343074487777677313, 'pay/alipaynotifylog', 0, 0, 'icon-filedone', 'pay:alipayNotifyLog:all', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1419551957005963266, 0, '', 0, 0, 'icon-wechat-fill', '', 3, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1419553543706972161, 1419551957005963266, 'mp/account', 0, 0, 'icon-user', 'mp:account:all', 0, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
INSERT INTO `sys_menu` VALUES (1419963799817691137, 1419551957005963266, 'mp/menu', 0, 0, 'icon-unorderedlist', 'mp:menu:all', 1, 0, 1067246875800000001, '2024-05-30 14:12:20', 1067246875800000001, '2024-05-30 14:12:20');
COMMIT;

-- ----------------------------
-- Table structure for sys_notice
-- ----------------------------
DROP TABLE IF EXISTS `sys_notice`;
CREATE TABLE `sys_notice` (
  `id` bigint NOT NULL COMMENT 'id',
  `notice_type` int NOT NULL COMMENT '通知类型',
  `title` varchar(200) DEFAULT NULL COMMENT '标题',
  `content` text COMMENT '内容',
  `receiver_type` tinyint unsigned DEFAULT NULL COMMENT '接收者  0：全部  1：部门',
  `receiver_type_ids` varchar(500) DEFAULT NULL COMMENT '接收者ID，用逗号分开',
  `status` tinyint unsigned DEFAULT NULL COMMENT '发送状态  0：草稿  1：已发布',
  `sender_name` varchar(50) DEFAULT NULL COMMENT '发送者',
  `sender_date` datetime DEFAULT NULL COMMENT '发送时间',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='通知管理';

-- ----------------------------
-- Records of sys_notice
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_notice_user
-- ----------------------------
DROP TABLE IF EXISTS `sys_notice_user`;
CREATE TABLE `sys_notice_user` (
  `receiver_id` bigint NOT NULL COMMENT '接收者ID',
  `notice_id` bigint NOT NULL COMMENT '通知ID',
  `read_status` tinyint unsigned DEFAULT NULL COMMENT '阅读状态  0：未读  1：已读',
  `read_date` datetime DEFAULT NULL COMMENT '阅读时间',
  PRIMARY KEY (`receiver_id`,`notice_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='我的通知';

-- ----------------------------
-- Records of sys_notice_user
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_oauth_client_details
-- ----------------------------
DROP TABLE IF EXISTS `sys_oauth_client_details`;
CREATE TABLE `sys_oauth_client_details` (
  `client_id` varchar(128) NOT NULL COMMENT '客户端id',
  `resource_ids` varchar(128) DEFAULT NULL COMMENT '资源ids',
  `client_secret` varchar(128) DEFAULT NULL COMMENT '客户端密钥',
  `scope` varchar(128) DEFAULT NULL COMMENT '授权范围',
  `authorized_grant_types` varchar(128) DEFAULT NULL COMMENT '授权类型',
  `web_server_redirect_uri` varchar(128) DEFAULT NULL COMMENT '回调地址',
  `authorities` varchar(128) DEFAULT NULL COMMENT '权限标识',
  `access_token_validity` int DEFAULT NULL COMMENT '访问令牌有效期',
  `refresh_token_validity` int DEFAULT NULL COMMENT '刷新令牌有效期',
  `additional_information` varchar(4096) DEFAULT NULL COMMENT '附加信息',
  `autoapprove` varchar(128) DEFAULT NULL COMMENT '自动授权',
  PRIMARY KEY (`client_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='OAuth客户端令牌';

-- ----------------------------
-- Records of sys_oauth_client_details
-- ----------------------------
BEGIN;
INSERT INTO `sys_oauth_client_details` VALUES ('renren-sso-demo', '', '$2a$10$aiWOK7GmRzyLyRihSF0cMedcbsEo0t11/y8f.tnBkF2hCeSd0Bq.i', 'all', 'authorization_code,password,implicit,client_credentials,refresh_token', 'http://localhost:8090/sso/login', NULL, 50000, NULL, NULL, 'true');
INSERT INTO `sys_oauth_client_details` VALUES ('renrenio', '', '$2a$10$aiWOK7GmRzyLyRihSF0cMedcbsEo0t11/y8f.tnBkF2hCeSd0Bq.i', 'all', 'authorization_code,password,implicit,client_credentials,refresh_token', 'https://www.renren.io/', NULL, 50000, NULL, NULL, 'true');
COMMIT;

-- ----------------------------
-- Table structure for sys_oss
-- ----------------------------
DROP TABLE IF EXISTS `sys_oss`;
CREATE TABLE `sys_oss` (
  `id` bigint NOT NULL COMMENT 'id',
  `url` varchar(200) DEFAULT NULL COMMENT 'URL地址',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='文件上传';

-- ----------------------------
-- Records of sys_oss
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_params
-- ----------------------------
DROP TABLE IF EXISTS `sys_params`;
CREATE TABLE `sys_params` (
  `id` bigint NOT NULL COMMENT 'id',
  `param_code` varchar(32) DEFAULT NULL COMMENT '参数编码',
  `param_value` varchar(2000) DEFAULT NULL COMMENT '参数值',
  `param_type` tinyint unsigned DEFAULT '1' COMMENT '类型   0：系统参数   1：非系统参数',
  `remark` varchar(200) DEFAULT NULL COMMENT '备注',
  `del_flag` tinyint unsigned DEFAULT NULL COMMENT '删除标识  0：未删除    1：删除',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_param_code` (`param_code`),
  KEY `idx_del_flag` (`del_flag`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='参数管理';

-- ----------------------------
-- Records of sys_params
-- ----------------------------
BEGIN;
INSERT INTO `sys_params` VALUES (1067246875800000072, 'DEV_TOOLS_PARAM_KEY', '{\"packageName\":\"com.example\",\"version\":\"3.0\",\"author\":\"Mark\",\"email\":\"sunlightcs@gmail.com\",\"backendPath\":\"D:\\\\qario\\\\qar-cloud-tenant\\\\qar-admin\",\"frontendPath\":\"D:\\\\qario\\\\qar-cloud-tenant-admin\"}', 0, '代码生成器配置信息', 0, 1067246875800000001, '2024-05-30 14:14:18', 1067246875800000001, '2024-05-30 14:14:18');
INSERT INTO `sys_params` VALUES (1067246875800000145, 'MAIL_CONFIG_KEY', '{\"smtp\":\"smtp.163.com\",\"port\":25,\"username\":\"qario_test@163.com\",\"password\":\"qar123456\"}', 0, '邮件配置信息', 0, 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
INSERT INTO `sys_params` VALUES (1067246875800000167, 'CLOUD_STORAGE_CONFIG_KEY', '{\"type\":1,\"qiniuDomain\":\"http://pgzjvphhb.bkt.clouddn.com\",\"qiniuPrefix\":\"upload\",\"qiniuAccessKey\":\"NrgMfABZxWLo5B-YYSjoE8-AZ1EISdi1Z3ubLOeZ\",\"qiniuSecretKey\":\"uIwJHevMRWU0VLxFvgy0tAcOdGqasdtVlJkdy6vV\",\"qiniuBucketName\":\"qar-oss\",\"aliyunDomain\":\"\",\"aliyunPrefix\":\"\",\"aliyunEndPoint\":\"\",\"aliyunAccessKeyId\":\"\",\"aliyunAccessKeySecret\":\"\",\"aliyunBucketName\":\"\",\"qcloudDomain\":\"\",\"qcloudPrefix\":\"\",\"qcloudSecretId\":\"\",\"qcloudSecretKey\":\"\",\"qcloudBucketName\":\"\"}', 0, '云存储配置信息', 0, 1067246875800000001, '2024-05-30 14:15:12', 1067246875800000001, '2024-05-30 14:15:12');
COMMIT;

-- ----------------------------
-- Table structure for sys_post
-- ----------------------------
DROP TABLE IF EXISTS `sys_post`;
CREATE TABLE `sys_post` (
  `id` bigint NOT NULL COMMENT 'id',
  `post_code` varchar(100) DEFAULT NULL COMMENT '岗位编码',
  `post_name` varchar(100) DEFAULT NULL COMMENT '岗位名称',
  `sort` int DEFAULT NULL COMMENT '排序',
  `status` tinyint DEFAULT NULL COMMENT '状态  0：停用   1：正常',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='岗位管理';

-- ----------------------------
-- Records of sys_post
-- ----------------------------
BEGIN;
INSERT INTO `sys_post` VALUES (1341597192832811009, 'tech', '技术岗', 0, 1, 1067246875800000001, '2024-05-30 14:12:22', 1067246875800000001, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for sys_region
-- ----------------------------
DROP TABLE IF EXISTS `sys_region`;
CREATE TABLE `sys_region` (
  `id` bigint NOT NULL COMMENT 'id',
  `pid` bigint DEFAULT NULL COMMENT '上级ID，一级为0',
  `name` varchar(100) DEFAULT NULL COMMENT '名称',
  `tree_level` tinyint DEFAULT NULL COMMENT '层级',
  `leaf` tinyint DEFAULT NULL COMMENT '是否叶子节点  0：否   1：是',
  `sort` bigint DEFAULT NULL COMMENT '排序',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='行政区域';

-- ----------------------------
-- Records of sys_region
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_role
-- ----------------------------
DROP TABLE IF EXISTS `sys_role`;
CREATE TABLE `sys_role` (
  `id` bigint NOT NULL COMMENT 'id',
  `name` varchar(32) DEFAULT NULL COMMENT '角色名称',
  `remark` varchar(100) DEFAULT NULL COMMENT '备注',
  `del_flag` tinyint unsigned DEFAULT NULL COMMENT '删除标识  0：未删除    1：删除',
  `dept_id` bigint DEFAULT NULL COMMENT '部门ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  KEY `idx_dept_id` (`dept_id`),
  KEY `idx_del_flag` (`del_flag`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色管理';

-- ----------------------------
-- Records of sys_role
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_role_data_scope
-- ----------------------------
DROP TABLE IF EXISTS `sys_role_data_scope`;
CREATE TABLE `sys_role_data_scope` (
  `id` bigint NOT NULL COMMENT 'id',
  `role_id` bigint DEFAULT NULL COMMENT '角色ID',
  `dept_id` bigint DEFAULT NULL COMMENT '部门ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_role_id` (`role_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色数据权限';

-- ----------------------------
-- Records of sys_role_data_scope
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_role_menu
-- ----------------------------
DROP TABLE IF EXISTS `sys_role_menu`;
CREATE TABLE `sys_role_menu` (
  `id` bigint NOT NULL COMMENT 'id',
  `role_id` bigint DEFAULT NULL COMMENT '角色ID',
  `menu_id` bigint DEFAULT NULL COMMENT '菜单ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_role_id` (`role_id`),
  KEY `idx_menu_id` (`menu_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色菜单关系';

-- ----------------------------
-- Records of sys_role_menu
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_role_user
-- ----------------------------
DROP TABLE IF EXISTS `sys_role_user`;
CREATE TABLE `sys_role_user` (
  `id` bigint NOT NULL COMMENT 'id',
  `role_id` bigint DEFAULT NULL COMMENT '角色ID',
  `user_id` bigint DEFAULT NULL COMMENT '用户ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_role_id` (`role_id`),
  KEY `idx_user_id` (`user_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='角色用户关系';

-- ----------------------------
-- Records of sys_role_user
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_sms
-- ----------------------------
DROP TABLE IF EXISTS `sys_sms`;
CREATE TABLE `sys_sms` (
  `id` bigint NOT NULL COMMENT 'id',
  `sms_code` varchar(32) DEFAULT NULL COMMENT '短信编码',
  `platform` tinyint unsigned NOT NULL COMMENT '平台类型',
  `sms_config` varchar(2000) DEFAULT NULL COMMENT '短信配置',
  `remark` varchar(200) DEFAULT NULL COMMENT '备注',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_sms_code` (`sms_code`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='短信';

-- ----------------------------
-- Records of sys_sms
-- ----------------------------
BEGIN;
INSERT INTO `sys_sms` VALUES (1228954061084676097, '1001', 1, '{\"aliyunAccessKeyId\":\"1\",\"aliyunAccessKeySecret\":\"1\",\"aliyunSignName\":\"1\",\"aliyunTemplateCode\":\"1\",\"qcloudAppKey\":\"\",\"qcloudSignName\":\"\",\"qcloudTemplateId\":\"\",\"qiniuAccessKey\":\"\",\"qiniuSecretKey\":\"\",\"qiniuTemplateId\":\"\"}', '', 1067246875800000001, '2024-05-30 14:14:47', 1067246875800000001, '2024-05-30 14:14:47');
COMMIT;

-- ----------------------------
-- Table structure for sys_sms_log
-- ----------------------------
DROP TABLE IF EXISTS `sys_sms_log`;
CREATE TABLE `sys_sms_log` (
  `id` bigint NOT NULL COMMENT 'id',
  `sms_code` varchar(32) DEFAULT NULL COMMENT '短信编码',
  `platform` tinyint unsigned NOT NULL COMMENT '平台类型',
  `mobile` varchar(20) DEFAULT NULL COMMENT '手机号',
  `params_1` varchar(50) DEFAULT NULL COMMENT '参数1',
  `params_2` varchar(50) DEFAULT NULL COMMENT '参数2',
  `params_3` varchar(50) DEFAULT NULL COMMENT '参数3',
  `params_4` varchar(50) DEFAULT NULL COMMENT '参数4',
  `status` tinyint unsigned DEFAULT NULL COMMENT '发送状态  0：失败  1：成功',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_sms_code` (`sms_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='短信日志';

-- ----------------------------
-- Records of sys_sms_log
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_ureport_data
-- ----------------------------
DROP TABLE IF EXISTS `sys_ureport_data`;
CREATE TABLE `sys_ureport_data` (
  `id` bigint NOT NULL COMMENT 'id',
  `file_name` varchar(200) DEFAULT NULL COMMENT '报表文件名',
  `content` mediumblob COMMENT '内容',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='报表数据';

-- ----------------------------
-- Records of sys_ureport_data
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_user
-- ----------------------------
DROP TABLE IF EXISTS `sys_user`;
CREATE TABLE `sys_user` (
  `id` bigint NOT NULL COMMENT 'id',
  `username` varchar(50) DEFAULT NULL COMMENT '用户名',
  `password` varchar(100) DEFAULT NULL COMMENT '密码',
  `real_name` varchar(50) DEFAULT NULL COMMENT '姓名',
  `head_url` varchar(200) DEFAULT NULL COMMENT '头像',
  `gender` tinyint unsigned DEFAULT NULL COMMENT '性别   0：男   1：女    2：保密',
  `email` varchar(100) DEFAULT NULL COMMENT '邮箱',
  `mobile` varchar(20) DEFAULT NULL COMMENT '手机号',
  `dept_id` bigint DEFAULT NULL COMMENT '部门ID',
  `super_admin` tinyint unsigned DEFAULT NULL COMMENT '超级管理员   0：否   1：是',
  `status` tinyint DEFAULT NULL COMMENT '状态  0：停用   1：正常',
  `remark` varchar(200) DEFAULT NULL COMMENT '备注',
  `del_flag` tinyint unsigned DEFAULT NULL COMMENT '删除标识  0：未删除    1：删除',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_username` (`username`),
  KEY `idx_del_flag` (`del_flag`),
  KEY `idx_create_date` (`create_date`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='用户管理';

-- ----------------------------
-- Records of sys_user
-- ----------------------------
BEGIN;
INSERT INTO `sys_user` VALUES (1067246875800000001, 'admin', '$2a$10$012Kx2ba5jzqr9gLlG4MX.bnQJTD9UWqF57XDo2N3.fPtLne02u/m', '超级管理员', NULL, 1, 'root@renren.io', '13512345678', NULL, 1, 1, NULL, 0, NULL, '2024-05-30 14:12:19', NULL, '2024-05-30 14:12:19');
COMMIT;

-- ----------------------------
-- Table structure for sys_user_post
-- ----------------------------
DROP TABLE IF EXISTS `sys_user_post`;
CREATE TABLE `sys_user_post` (
  `id` bigint NOT NULL COMMENT 'id',
  `post_id` bigint DEFAULT NULL COMMENT '岗位ID',
  `user_id` bigint DEFAULT NULL COMMENT '用户ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  KEY `idx_post_id` (`post_id`),
  KEY `idx_user_id` (`user_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='用户岗位关系';

-- ----------------------------
-- Records of sys_user_post
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for tb_alipay_notify_log
-- ----------------------------
DROP TABLE IF EXISTS `tb_alipay_notify_log`;
CREATE TABLE `tb_alipay_notify_log` (
  `id` bigint NOT NULL COMMENT 'id',
  `out_trade_no` bigint DEFAULT NULL COMMENT '订单号',
  `total_amount` decimal(10,2) DEFAULT NULL COMMENT '订单金额',
  `buyer_pay_amount` decimal(10,2) DEFAULT NULL COMMENT '付款金额',
  `receipt_amount` decimal(10,2) DEFAULT NULL COMMENT '实收金额',
  `invoice_amount` decimal(10,2) DEFAULT NULL COMMENT '开票金额',
  `notify_id` varchar(50) DEFAULT NULL COMMENT '通知校验ID',
  `buyer_id` varchar(50) DEFAULT NULL COMMENT '买家支付宝用户号',
  `seller_id` varchar(50) DEFAULT NULL COMMENT '卖家支付宝用户号',
  `trade_no` varchar(50) DEFAULT NULL COMMENT '支付宝交易号',
  `trade_status` varchar(50) DEFAULT NULL COMMENT '交易状态',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='支付宝回调日志';

-- ----------------------------
-- Records of tb_alipay_notify_log
-- ----------------------------
BEGIN;
INSERT INTO `tb_alipay_notify_log` VALUES (1343493644518195201, 1343491774781419523, 3600.00, 3600.00, 3600.00, 3600.00, '2020122800222174658006930510128003', '2088102177806934', '2088102177441441', '2020122822001406930501194003', 'TRADE_SUCCESS', '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for tb_excel_data
-- ----------------------------
DROP TABLE IF EXISTS `tb_excel_data`;
CREATE TABLE `tb_excel_data` (
  `id` bigint NOT NULL COMMENT 'id',
  `real_name` varchar(100) DEFAULT NULL COMMENT '学生姓名',
  `user_identity` varchar(100) DEFAULT NULL COMMENT '身份证',
  `address` varchar(200) DEFAULT NULL COMMENT '家庭地址',
  `join_date` datetime DEFAULT NULL COMMENT '入学日期',
  `class_name` varchar(100) DEFAULT NULL COMMENT '班级名称',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='Excel导入演示';

-- ----------------------------
-- Records of tb_excel_data
-- ----------------------------
BEGIN;
INSERT INTO `tb_excel_data` VALUES (1343762012112445441, '大力', '430212199910102980', '上海市长宁区中山公园', '2024-05-30 14:12:22', '姚班2101', 1067246875800000001, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for tb_news
-- ----------------------------
DROP TABLE IF EXISTS `tb_news`;
CREATE TABLE `tb_news` (
  `id` bigint NOT NULL COMMENT 'id',
  `title` varchar(255) NOT NULL COMMENT '标题',
  `content` mediumtext NOT NULL COMMENT '内容',
  `pub_date` datetime DEFAULT NULL COMMENT '发布时间',
  `dept_id` bigint DEFAULT NULL COMMENT '创建者dept_id',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='新闻管理';

-- ----------------------------
-- Records of tb_news
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for tb_order
-- ----------------------------
DROP TABLE IF EXISTS `tb_order`;
CREATE TABLE `tb_order` (
  `id` bigint NOT NULL COMMENT 'id',
  `order_id` bigint DEFAULT NULL COMMENT '订单ID',
  `product_id` bigint NOT NULL COMMENT '产品ID',
  `product_name` varchar(100) DEFAULT NULL COMMENT '产品名称',
  `pay_amount` decimal(10,2) NOT NULL COMMENT '支付金额',
  `status` tinyint DEFAULT NULL COMMENT '订单状态  -1：已取消   0：等待付款   1：已完成',
  `user_id` bigint DEFAULT NULL COMMENT '购买用户ID',
  `pay_at` datetime DEFAULT NULL COMMENT '支付时间',
  `create_date` datetime DEFAULT NULL COMMENT '下单时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `uk_order_id` (`order_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='订单';

-- ----------------------------
-- Records of tb_order
-- ----------------------------
BEGIN;
INSERT INTO `tb_order` VALUES (1343491774781419523, 1343491774781419523, 1, 'qar企业版', 3600.00, 1, 1067246875800000001, '2024-05-30 14:12:22', '2024-05-30 14:12:22');
INSERT INTO `tb_order` VALUES (1343491827268939779, 1343491827268939778, 2, 'qar微服务版', 4800.00, 0, 1067246875800000001, NULL, '2024-05-30 14:12:22');
COMMIT;

-- ----------------------------
-- Table structure for tb_product
-- ----------------------------
DROP TABLE IF EXISTS `tb_product`;
CREATE TABLE `tb_product` (
  `id` bigint NOT NULL COMMENT 'id',
  `name` varchar(100) NOT NULL COMMENT '产品名称',
  `content` mediumtext NOT NULL COMMENT '产品介绍',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='产品管理';

-- ----------------------------
-- Records of tb_product
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for tb_product_params
-- ----------------------------
DROP TABLE IF EXISTS `tb_product_params`;
CREATE TABLE `tb_product_params` (
  `id` bigint NOT NULL COMMENT 'id',
  `param_name` varchar(100) DEFAULT NULL COMMENT '参数名',
  `param_value` varchar(200) DEFAULT NULL COMMENT '参数值',
  `product_id` bigint DEFAULT NULL COMMENT '产品ID',
  `creator` bigint DEFAULT NULL COMMENT '创建者',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  `updator` bigint DEFAULT NULL COMMENT '更新者',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='产品参数管理';

-- ----------------------------
-- Records of tb_product_params
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for tb_token
-- ----------------------------
DROP TABLE IF EXISTS `tb_token`;
CREATE TABLE `tb_token` (
  `id` bigint NOT NULL COMMENT 'id',
  `user_id` bigint NOT NULL COMMENT '用户ID',
  `token` varchar(100) NOT NULL COMMENT 'token',
  `expire_date` datetime DEFAULT NULL COMMENT '过期时间',
  `update_date` datetime DEFAULT NULL COMMENT '更新时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `user_id` (`user_id`),
  UNIQUE KEY `token` (`token`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='用户Token';

-- ----------------------------
-- Records of tb_token
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for tb_user
-- ----------------------------
DROP TABLE IF EXISTS `tb_user`;
CREATE TABLE `tb_user` (
  `id` bigint NOT NULL COMMENT 'id',
  `username` varchar(50) NOT NULL COMMENT '用户名',
  `mobile` varchar(20) NOT NULL COMMENT '手机号',
  `password` varchar(64) DEFAULT NULL COMMENT '密码',
  `create_date` datetime DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`id`),
  UNIQUE KEY `username` (`username`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COMMENT='用户';

-- ----------------------------
-- Records of tb_user
-- ----------------------------
BEGIN;
INSERT INTO `tb_user` VALUES (1067246875800000168, 'mark', '13612345678', '8c6976e5b5410415bde908bd4dee15dfb167a9c873fc4bb8a81f6f2ab448a918', '2024-05-30 14:17:18');
COMMIT;

-- ----------------------------
-- Table structure for user
-- ----------------------------
DROP TABLE IF EXISTS `user`;
CREATE TABLE `user` (
  `user_id` int NOT NULL AUTO_INCREMENT COMMENT '用户ID',
  `setmeal_id` int NOT NULL COMMENT '套餐ID',
  `openid` varchar(255) NOT NULL COMMENT '开放ID',
  `name` varchar(100) NOT NULL COMMENT '用户名',
  `phone` varchar(11) NOT NULL COMMENT '电话号码',
  `sex` enum('male','female') DEFAULT NULL COMMENT '性别',
  `identification` varchar(18) NOT NULL COMMENT '身份证号码',
  `avatar` varchar(255) DEFAULT NULL COMMENT '头像URL',
  `email` varchar(100) DEFAULT NULL COMMENT '电子邮件',
  `email_verified` tinyint(1) NOT NULL DEFAULT '0' COMMENT '电子邮件验证状态',
  `username` varchar(50) DEFAULT NULL COMMENT '登录用户名',
  `password_hash` varchar(255) NOT NULL COMMENT '密码哈希值',
  `province` char(20) DEFAULT NULL COMMENT '省份',
  `city` char(20) DEFAULT NULL COMMENT '城市',
  `district` char(20) DEFAULT NULL COMMENT '区县',
  `detail_address` varchar(100) DEFAULT NULL COMMENT '详细地址',
  PRIMARY KEY (`user_id`),
  UNIQUE KEY `openid` (`openid`),
  UNIQUE KEY `email` (`email`),
  UNIQUE KEY `username` (`username`),
  KEY `idx_username` (`username`),
  KEY `idx_email` (`email`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='用户表';

-- ----------------------------
-- Records of user
-- ----------------------------
BEGIN;
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
